package ken.spring.cloud.alibaba;

import org.springframework.cloud.stream.annotation.StreamListener;
import org.springframework.stereotype.Service;

/**
 * <ul>
 * <li>Title: ReceiveService</li>
 * <li>Description: 消息接收方 </li>
 * </ul>
 *
 * @author swc
 * @date 2022-07-06 15:34
 */
@Service
public class MqReceiveService {

    @StreamListener("msgInput1")
    public void receiveOutput(String receiveMsg) {
        System.out.println("msgInput1 receive: " + receiveMsg);
    }

    @StreamListener("msgTransactionalInput2")
    public void msgTransactionalOutput2(String receiveMsg) {
        System.out.println("msgTransactionalInput2 receive: " + receiveMsg);
    }

}
